#pragma once

#define		MaxInsLen			20
#define		MaxInsNum			100

#define CMDARGVLEN              5
#define CMDSTRLEN               20

typedef enum {
	InsHelp = 0,
	InsSet,
	InsGet,
	InsAction,
	InsNum,
}InsType_t;

typedef struct {
	char Ins[MaxInsNum][MaxInsLen];
	uint8_t effInsNum;
	void(*cmdCB[MaxInsNum])(void*);
}CmdIns_t;

typedef struct {
	bool hasInf;
	uint8_t argc;
	char* argv[MaxInsLen];
	CmdIns_t CmdIns[InsNum];
}CmdHandle_t;

void uart0_rx_task(void *pvParameters);
bool MyCMDRegisterIns(CmdHandle_t* CmdHandle, InsType_t type, char* Ins, void (*CB)(void*));

